<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
        "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:ui="http://java.sun.com/jsf/facelets"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:f="http://java.sun.com/jsf/core"
      xmlns:c="http://java.sun.com/jsp/jstl/core"
      xmlns:p="http://primefaces.org/ui">
	
    <h:head>
        <title>PDS-LOGIN</title>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
        <meta http-equiv="X-UA-Compatible" content="IE=9" />
        <h:outputStylesheet library="resource" name="css/login.css"/>
    	<h:outputScript library="resource" name="js/login.js" />
    	<h:outputScript library="resource" name="js/jquery-2.1.1.js" />
    </h:head>
    <h:body>
    	<!-- VARIABLES -->
    	<c:set var="keyCode" value="#{userSessionBean.keyCode}"/>
    	
		<div id="header">
			<div id="header_content">
			</div>
		</div>
		<div id="content">
			<div id="wrapper">
				<div id="wrapper_login">
				
					<div id="wrapper_header">
						<h:outputLabel value="#{scrText['screen.login.etiqueta.header.title']}"/>
					</div>
					<div id="wrapper_content">
						<script language="javascript" type="text/javascript">
							$(document).ready(function() {
					        	initLoginAction();
					        });
						</script>
						<h:form prependId="false">
						
							<h:outputLabel value="#{scrText['screen.login.etiqueta.username']}:"/>
							<h:panelGrid columns="2" style="margin-left: 30px;">
								<h:inputText id="username" value="#{userSessionBean.username}" required="true"
									style="text-transform: lowercase;" tabindex="1" styleClass="input"
									onkeypress="return checkEvent(event, #{keyCode}, this);">
                    			</h:inputText>
                    			<p:message for="username" />
							</h:panelGrid>
					
							<h:outputLabel value="#{scrText['screen.login.etiqueta.password']}:"/>
							<h:panelGrid columns="2" style="margin-left: 30px; padding-bottom: 20px;">
								<h:inputSecret id="password" value="#{userSessionBean.password}" required="true"
									onkeypress="return checkEvent(event, #{keyCode}, this);" 
									style="text-transform: lowercase;" tabindex="2" styleClass="input">
                    			</h:inputSecret>
                    			<p:message for="password" />
							</h:panelGrid>
					
							<h:panelGrid columns="2" styleClass="panelButtonLogin">
								<h:commandButton id="button" value="#{scrText['screen.login.etiqueta.sigin']}" styleClass="button" 
									tabindex="3" action="#{credentialsBean.authenticationAction(userSessionBean)}">
	           					</h:commandButton>
	           				</h:panelGrid>
	           				
	           			</h:form>
					</div>
					<div id="wrapper_footer">
						<h:outputLabel value="#{scrText['screen.login.etiqueta.forgot']} "/>
					</div>
				</div>
				<div id="wrapper_background"></div>
			</div>
		</div>
		<div id="footer"></div>
    </h:body>

</html>